<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>查看个人信息</title>
<link href="<%=request.getContextPath()%>/css/css.css" rel="stylesheet" type="text/css">
<script language="javascript">
	function UpdateInfo(){
	
	
	location.href="<%=request.getContextPath()%>/ToEditUserInfoServlet.do?uname=${userInfo.userName}"
	
	}
</script>
</head>
<body class="write_bg">
<form name="form1" method="post" action="">
  <table width="100%" border="0" cellspacing="0">
    <tr>
      <td height="30">&nbsp;</td>
    </tr>
  </table>
  <table width="835" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="20" colspan="2" align="center" ></td>
  </tr>
  <tr>
    <td width="64" align="center" ></td>
    <td width="771" height="30" align="left" valign="top" ><span class="text_blod_title">查看个人信息</span></td>
  </tr>
  <tr>
    <td height="15" colspan="2" ><img src="../images/line1.jpg" width="835" height="6"></td>
  </tr>
  <tr>
    <td colspan="2" valign="top"  ><table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td height="20" colspan="4"  ></td>
          </tr>
          <tr>
            <td height="15" colspan="4" align="left" class="text_title">个人详细信息</td>
          </tr>
          <tr>
            <td height="10" colspan="4" ></td>
          </tr>
          
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">登录名：</td>
            <td width="350" align="left" class="text_cray">${userInfo.userName}</td>
            <td width="230" rowspan="5" align="center" background="../images/bg_point_write.gif" class="text_cray">
             <c:if test="${empty user.headImage}">
           		 <td width="239" rowspan="6" align="center" ><img src="<%=request.getContextPath()%>/images/photo.jpg" width="120" height="120"></td>
            </c:if>
            <c:if test="${not empty user.headImage}">
           		 <td width="239" rowspan="6" align="center" ><img src="<%=request.getContextPath()%>/${user.headImage}" width="120" height="120"></td>
            </c:if>
            </td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">真实姓名：</td>
            <td align="left" class="text_cray">${userInfo.trueName}</td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">性 别：</td>
            <td align="left" class="text_cray">
            	<c:if test="${userInfo.sex eq 'M'}">
					<c:out value="男"></c:out>
            	
            	</c:if>
            	<c:if test="${userInfo.sex eq 'F'}">
	            	<c:out value="女"></c:out>
            	
            	</c:if>
            </td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">省份：</td>
            <td align="left" class="text_cray">${userInfo.province}</td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">城市：</td>
            <td align="left" class="text_cray">${userInfo.city}</td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">证件类型：</td>
            <td colspan="2" align="left" class="text_cray">
            	<c:choose>
            		<c:when test="${userInfo.cardType eq '1'}">
            		<c:out value="二代身份证"></c:out>
            		</c:when>
            	</c:choose>
            	
              	<c:choose>
            		<c:when test="${userInfo.cardType eq 'C'}">
            		<c:out value="港澳通行证"></c:out>
            			
            		</c:when>
            		
            	</c:choose>
            	
            	<c:choose>
            		<c:when test="${userInfo.cardType eq 'G'}">
            		<c:out value="台湾通行证"></c:out>
            		</c:when>
            		
            	</c:choose>
            	
            	<c:choose>
            		<c:when test="${userInfo.cardType eq 'B'}">
            			 <c:out value="护照"></c:out>
            		</c:when>
            		
            	</c:choose>
            </td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">证件号码：</td>
            <td colspan="2" align="left" class="text_cray">${userInfo.idNumber}</td>
          </tr>
          <tr>
            <td width="20" height="40" align="center" class="text_red">*</td>
            <td width="100" height="40" align="left" class="text_cray1">出生日期：</td>
            <td colspan="2" align="left" class="text_cray">${userInfo.birthDate}</td>
          </tr>
          <tr>
            <td width="20" height="40" ></td>
            <td width="100" height="40" align="left" class="text_cray1">旅客类型：</td>
            <td colspan="3" align="left" class="text_cray">
            	<c:choose>
            		<c:when test="${userInfo.passengerType eq '1'}">
            			 <c:out value="成人"></c:out>
            		</c:when>            		
            	</c:choose>
               
               <c:choose>
            		<c:when test="${userInfo.passengerType eq '2'}">
            			 <c:out value="儿童"></c:out>
            		</c:when>
            	</c:choose>
            	
            	<c:choose>
            		<c:when test="${userInfo.passengerType eq '3'}">
            			  <c:out value="学生"></c:out>
            		</c:when>
            	</c:choose>
            	
            	<c:choose>
            		<c:when test="${userInfo.passengerType eq '4'}">
            			 <c:out value="残疾军人、伤残人民警察"></c:out>
            		</c:when>
            	</c:choose>
            </td>
          </tr>
          <tr>
            <td width="20" height="40"></td>
            <td width="100" height="40" align="left" class="text_cray1">备注：</td>
            <td height="40" colspan="2" align="left" class="text_cray">${userInfo.tips}</td>
          </tr>
        </table><br>
      <table width="100%" border="0" cellspacing="0">
        <tr>
          <td></td>
        </tr>
      </table>
      <table width="263" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <td height="30" align="center"><input name="button" type="button" class="butxg" id="button"value="" onClick="UpdateInfo()"></td>
          </tr>
      </table>
    </table>
  <table width="100%" border="0" cellspacing="0">
    <tr>
      <td height="20"></td>
    </tr>
  </table>  
  <table width="100%" border="0" cellspacing="0">
    <tr>
      <td height="2" background="<%=request.getContextPath()%>/images/bottom_point.gif"></td>
    </tr>
    <tr>
      <td height="25" align="center" background="<%=request.getContextPath()%>/images/bottom_ny_bg.gif" class="text_cray">copyright@12306 购票网</td>
    </tr>
  </table>
  </td>
  </tr>
</table>
</form>
</body>
</html>
